import request from '@/request/request.js'

// 登录
export default {
    // 租房列表
    rental(params) {
        return request({
          url: "/houseSearch/rent/list",
          method: "get",
          params: {
            ...params,
            pageSize: 1000,
            pageNum: 1
          }
        });
      },
    // 获取租房用户信息
      getTtentList(params) {
        return request({
          url: "/houseSearch/tenant/list",
          method: "get",
          params
        });
      },

    getHouseDetail(rentId) {
      return request({
          url: `/houseSearch/rent/${rentId}`,
          method: "get",
      });
    },
    /**
     * 获取租客详情信息
    */
    getTenantDetail(tenantId) {
      return request({
        url: `/houseSearch/tenant/${tenantId}`,
        method: 'Get'
      })
    },
    /**
     * 租客上报删除
    */
    delTenant(tenantId) {
      return request({
        url: `/houseSearch/tenant/${tenantId}`,
        method: 'delete'
      })
    },
    /**
     * 租客上报修改
     */
    updateTenant(params) {
      return request({
        url: `/houseSearch/tenant`,
        method: 'Put',
        data: params
      })
    }
}